<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" />
    <title>ShellCheck: GitHub-Actions – Differential ShellCheck</title>
    <link rel="stylesheet" href="css/bootstrap.min.css" />
  </head>
  <body style="margin-left: auto; margin-right: auto; max-width: 800px">
    <h1>GitHub-Actions – ShellCheck Wiki</h1>
    <a href="https://github.com/koalaman/shellcheck/wiki/GitHub-Actions">See this page on GitHub</a>
    <p style="display: none"><a href="index.html">Sitemap</a></p>
    <hr />
    <h2 id="differential-shellcheck">Differential ShellCheck</h2>
<p>GitHub action for running ShellCheck differentially. New findings are
reported directly at GitHub pull requests (using SARIF format).</p>
<ul>
<li>Source: <a
href="https://github.com/redhat-plumbers-in-action/differential-shellcheck">@redhat-plumbers-in-action/differential-shellcheck</a></li>
</ul>
<p><a
href="https://github.com/redhat-plumbers-in-action/differential-shellcheck#usage">Usage</a>:</p>
<div class="sourceCode" id="cb1"><pre
class="sourceCode yaml"><code class="sourceCode yaml"><span id="cb1-1"><a href="GitHub-Actions.html#cb1-1" aria-hidden="true" tabindex="-1"></a><span class="fu">name</span><span class="kw">:</span><span class="at"> Differential ShellCheck</span></span>
<span id="cb1-2"><a href="GitHub-Actions.html#cb1-2" aria-hidden="true" tabindex="-1"></a><span class="fu">on</span><span class="kw">:</span></span>
<span id="cb1-3"><a href="GitHub-Actions.html#cb1-3" aria-hidden="true" tabindex="-1"></a><span class="at">  </span><span class="fu">push</span><span class="kw">:</span></span>
<span id="cb1-4"><a href="GitHub-Actions.html#cb1-4" aria-hidden="true" tabindex="-1"></a><span class="at">    </span><span class="fu">branches</span><span class="kw">:</span><span class="at"> </span><span class="kw">[</span><span class="at"> main </span><span class="kw">]</span></span>
<span id="cb1-5"><a href="GitHub-Actions.html#cb1-5" aria-hidden="true" tabindex="-1"></a><span class="at">  </span><span class="fu">pull_request</span><span class="kw">:</span></span>
<span id="cb1-6"><a href="GitHub-Actions.html#cb1-6" aria-hidden="true" tabindex="-1"></a><span class="at">    </span><span class="fu">branches</span><span class="kw">:</span><span class="at"> </span><span class="kw">[</span><span class="at">main</span><span class="kw">]</span></span>
<span id="cb1-7"><a href="GitHub-Actions.html#cb1-7" aria-hidden="true" tabindex="-1"></a></span>
<span id="cb1-8"><a href="GitHub-Actions.html#cb1-8" aria-hidden="true" tabindex="-1"></a><span class="fu">permissions</span><span class="kw">:</span></span>
<span id="cb1-9"><a href="GitHub-Actions.html#cb1-9" aria-hidden="true" tabindex="-1"></a><span class="at">  </span><span class="fu">contents</span><span class="kw">:</span><span class="at"> read</span></span>
<span id="cb1-10"><a href="GitHub-Actions.html#cb1-10" aria-hidden="true" tabindex="-1"></a></span>
<span id="cb1-11"><a href="GitHub-Actions.html#cb1-11" aria-hidden="true" tabindex="-1"></a><span class="fu">jobs</span><span class="kw">:</span></span>
<span id="cb1-12"><a href="GitHub-Actions.html#cb1-12" aria-hidden="true" tabindex="-1"></a><span class="at">  </span><span class="fu">lint</span><span class="kw">:</span></span>
<span id="cb1-13"><a href="GitHub-Actions.html#cb1-13" aria-hidden="true" tabindex="-1"></a><span class="at">    </span><span class="fu">runs-on</span><span class="kw">:</span><span class="at"> ubuntu-latest</span></span>
<span id="cb1-14"><a href="GitHub-Actions.html#cb1-14" aria-hidden="true" tabindex="-1"></a></span>
<span id="cb1-15"><a href="GitHub-Actions.html#cb1-15" aria-hidden="true" tabindex="-1"></a><span class="at">    </span><span class="fu">permissions</span><span class="kw">:</span></span>
<span id="cb1-16"><a href="GitHub-Actions.html#cb1-16" aria-hidden="true" tabindex="-1"></a><span class="co">      # required for all workflows</span></span>
<span id="cb1-17"><a href="GitHub-Actions.html#cb1-17" aria-hidden="true" tabindex="-1"></a><span class="at">      </span><span class="fu">security-events</span><span class="kw">:</span><span class="at"> write</span></span>
<span id="cb1-18"><a href="GitHub-Actions.html#cb1-18" aria-hidden="true" tabindex="-1"></a></span>
<span id="cb1-19"><a href="GitHub-Actions.html#cb1-19" aria-hidden="true" tabindex="-1"></a><span class="co">      # only required for workflows in private repositories</span></span>
<span id="cb1-20"><a href="GitHub-Actions.html#cb1-20" aria-hidden="true" tabindex="-1"></a><span class="at">      </span><span class="fu">actions</span><span class="kw">:</span><span class="at"> read</span></span>
<span id="cb1-21"><a href="GitHub-Actions.html#cb1-21" aria-hidden="true" tabindex="-1"></a><span class="at">      </span><span class="fu">contents</span><span class="kw">:</span><span class="at"> read</span></span>
<span id="cb1-22"><a href="GitHub-Actions.html#cb1-22" aria-hidden="true" tabindex="-1"></a></span>
<span id="cb1-23"><a href="GitHub-Actions.html#cb1-23" aria-hidden="true" tabindex="-1"></a><span class="at">    </span><span class="fu">steps</span><span class="kw">:</span><span class="at"> </span></span>
<span id="cb1-24"><a href="GitHub-Actions.html#cb1-24" aria-hidden="true" tabindex="-1"></a><span class="at">      </span><span class="kw">-</span><span class="at"> </span><span class="fu">name</span><span class="kw">:</span><span class="at"> Repository checkout</span></span>
<span id="cb1-25"><a href="GitHub-Actions.html#cb1-25" aria-hidden="true" tabindex="-1"></a><span class="at">        </span><span class="fu">uses</span><span class="kw">:</span><span class="at"> actions/checkout@v4</span></span>
<span id="cb1-26"><a href="GitHub-Actions.html#cb1-26" aria-hidden="true" tabindex="-1"></a><span class="at">        </span><span class="fu">with</span><span class="kw">:</span></span>
<span id="cb1-27"><a href="GitHub-Actions.html#cb1-27" aria-hidden="true" tabindex="-1"></a><span class="at">          </span><span class="fu">fetch-depth</span><span class="kw">:</span><span class="at"> </span><span class="dv">0</span></span>
<span id="cb1-28"><a href="GitHub-Actions.html#cb1-28" aria-hidden="true" tabindex="-1"></a></span>
<span id="cb1-29"><a href="GitHub-Actions.html#cb1-29" aria-hidden="true" tabindex="-1"></a><span class="at">      </span><span class="kw">-</span><span class="at"> </span><span class="fu">name</span><span class="kw">:</span><span class="at"> Differential ShellCheck</span></span>
<span id="cb1-30"><a href="GitHub-Actions.html#cb1-30" aria-hidden="true" tabindex="-1"></a><span class="at">        </span><span class="fu">uses</span><span class="kw">:</span><span class="at"> redhat-plumbers-in-action/differential-shellcheck@v5</span></span>
<span id="cb1-31"><a href="GitHub-Actions.html#cb1-31" aria-hidden="true" tabindex="-1"></a><span class="at">        </span><span class="fu">with</span><span class="kw">:</span></span>
<span id="cb1-32"><a href="GitHub-Actions.html#cb1-32" aria-hidden="true" tabindex="-1"></a><span class="at">          </span><span class="fu">token</span><span class="kw">:</span><span class="at"> ${{ secrets.GITHUB_TOKEN }}</span></span></code></pre></div>
    <hr />
    <p style='font-size: 80%'><a href="../index.html">ShellCheck</a> is a static analysis tool for shell scripts. This page is part of its documentation.</p>
  </body>
</html>


